﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MicropleSoft.Common.Library
{
    public class Constant
    {
        /// <summary>
        /// 每个基础数据表都包含下面字段
        /// ITEM_ID INT PRIMARY KEY,/*内码*/
        /// ITEM_NUMBER VARCHAR(50),/*代码*/
        /// ITEM_NAME VARCHAR(50),/*名称*/
        /// PARENT_ID INT,/*父节点内码,关联ITEM_NODE(NODE_ID)*/
        /// STATUS INT,/*状态：1-正常，2-禁用*/
        /// 将固定字段逗号分隔
        /// </summary>
        public const string BaseDataCommonFieldComma = "ITEM_ID,ITEM_NUMBER,ITEM_NAME,PARENT_ID,STATUS";

        /// <summary>
        /// 每个基础数据表都包含下面字段
        /// ITEM_ID INT PRIMARY KEY,/*内码*/
        /// ITEM_NUMBER VARCHAR(50),/*代码*/
        /// ITEM_NAME VARCHAR(50),/*名称*/
        /// PARENT_ID INT,/*父节点内码,关联ITEM_NODE(NODE_ID)*/
        /// STATUS INT,/*状态：1-正常，2-禁用*/
        /// 将固定字段放入List
        /// </summary>
        public readonly static List<String> BaseDataCommonFieldList = new List<String>() { "ITEM_ID", "ITEM_NUMBER", "ITEM_NAME", "PARENT_ID", "STATUS" };

        /// <summary>
        /// 每个基础数据表都包含下面字段
        /// ITEM_ID INT PRIMARY KEY,/*内码*/
        /// ITEM_NUMBER VARCHAR(50),/*代码*/
        /// ITEM_NAME VARCHAR(50),/*名称*/
        /// PARENT_ID INT,/*父节点内码,关联ITEM_NODE(NODE_ID)*/
        /// STATUS INT,/*状态：1-正常，2-禁用*/
        /// 将固定字段中文名字放入List
        /// </summary>
        public readonly static List<String> BaseDataCommonFieldNameList = new List<String>() { "数据项ID", "数据项代码", "数据项名称", "父节点ID", "状态" };

        /// <summary>
        /// 基础数据主键
        /// </summary>
        public readonly static List<EntityKey> BaseDataCommonPrimaryField = new List<EntityKey>() { new EntityKey(){ PrimaryKeyName = "ITEM_ID",FPrimaryKeyType = PrimaryKeyType.PktNumeric} };
    }
}
